<template>
	<view class="shop">
		<view class="shop-item" v-for="(item,index) in dataList" :key="index">
			<view class="shop-big">
				<image class="shop-big" :src="item.bigUrl" mode=""></image>
			</view>
			
			<scroll-view scroll-x="true" class="scroll-content">
				<view class="scroll-item">
					<Commondity 
					:dataList="item.data" 
					warp="nowarp"
					itemW="200rpx"
					bigH="200rpx"
					></Commondity>
				</view>
			</scroll-view>
		</view>
	</view>
</template>

<script>
	import Commondity from "@/components/common/Commondity.vue"
	export default{
		props:{
			dataList:Array
		},
		data(){
			return{
				// shopList:[
				// 	{
				// 		id:1,
				// 		imgUrl:"../../static/img/3.webp",
				// 		name:"ssssssssssssssssssssssss",
				// 		pprice:"229",
				// 		oprice:"659",
				// 		discount:"5.2"
				// 	},
				// 	{
				// 		id:2,
				// 		imgUrl:"../../static/img/4.webp",
				// 		name:"ssssssssssssssssssssssss",
				// 		pprice:"229",
				// 		oprice:"659",
				// 		discount:"5.2"
				// 	},
				// 	{
				// 		id:3,
				// 		imgUrl:"../../static/img/2.webp",
				// 		name:"ssssssssssssssssssssssss",
				// 		pprice:"229",
				// 		oprice:"659",
				// 		discount:"5.2"
				// 	},
				// 	{
				// 		id:4,
				// 		imgUrl:"../../static/img/1.webp",
				// 		name:"ssssssssssssssssssssssss",
				// 		pprice:"229",
				// 		oprice:"659",
				// 		discount:"5.2"
				// 	}
				// ]
			}
		},
		components:{
			Commondity
		}
	}
</script>

<style scoped>
	.shop-big{
		width: 100%;
		height: 350rpx;
	}
	.scroll-content{
		width: 100%;
		white-space: nowrap;
	}
	.scroll-item{
		display: inline-block;
	}
</style>